package com.ruoyi.mk.service.impl;

import java.util.List;
import com.ruoyi.common.utils.DateUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.mk.mapper.MkQuotationMapper;
import com.ruoyi.mk.domain.MkQuotation;
import com.ruoyi.mk.service.IMkQuotationService;

/**
 * 官网用户报价Service业务层处理
 * @author ruoyi
 * @date 2025-06-24
 */
@Service
public class MkQuotationServiceImpl implements IMkQuotationService {

    @Autowired
    private MkQuotationMapper mkQuotationMapper;

    /**
     * 查询官网用户报价
     * @param id 官网用户报价主键
     * @return 官网用户报价
     */
    @Override
    public MkQuotation selectMkQuotationById(Long id) {
        return mkQuotationMapper.selectMkQuotationById(id);
    }

    /**
     * 查询官网用户报价列表
     * @param mkQuotation 官网用户报价
     * @return 官网用户报价
     */
    @Override
    public List<MkQuotation> selectMkQuotationList(MkQuotation mkQuotation) {
        return mkQuotationMapper.selectMkQuotationList(mkQuotation);
    }

    /**
     * 新增官网用户报价
     * 
     * @param mkQuotation 官网用户报价
     * @return 结果
     */
    @Override
    public int insertMkQuotation(MkQuotation mkQuotation) {
        mkQuotation.setCreateTime(DateUtils.getNowDate());
        return mkQuotationMapper.insertMkQuotation(mkQuotation);
    }

    /**
     * 修改官网用户报价
     * @param mkQuotation 官网用户报价
     * @return 结果
     */
    @Override
    public int updateMkQuotation(MkQuotation mkQuotation) {
        return mkQuotationMapper.updateMkQuotation(mkQuotation);
    }

    /**
     * 批量删除官网用户报价
     * @param ids 需要删除的官网用户报价主键
     * @return 结果
     */
    @Override
    public int deleteMkQuotationByIds(Long[] ids) {
        return mkQuotationMapper.deleteMkQuotationByIds(ids);
    }

    /**
     * 删除官网用户报价信息
     * @param id 官网用户报价主键
     * @return 结果
     */
    @Override
    public int deleteMkQuotationById(Long id) {
        return mkQuotationMapper.deleteMkQuotationById(id);
    }
}
